QueryDefinition Class

A "<Query>" element from an SLK Settings XML file, i.e. an XML file with schema "urn:schemas-microsoft-com:sharepoint-learning-kit:settings".

Namespace: Microsoft.SharePointLearningKit

Assembly: Microsoft.SharePointLearningKit.dll

Syntax
C#

public class QueryDefinition

Properties
Name Description
Ð Columns

Information about each "<Column>" child element.

Ð Conditions

Information about each "<Condition>" child element.

Ð CountViewColumnName

The value of the "CountViewColumnName" attribute. This is the name of a column in the LearningStore view specified by ViewName that can be used when the application needs to determine the number of rows returned in a query. In that situation, the query must include one column -- any column will do -- and it helps performance to make that column be one that contains small data (such as a boolean or integer column). If CountViewColumnName is null, the application will use the first column specified in Columns when creating count-only queries.

Ð Name

The value of the "Name" attribute. This is the unique internal name of the query; use Title if you want a human-readable label.

Ð Sorts

Information about each "<Sort>" child element.

Ð Title

The value of the "Title" attribute. This is the human-readable label of the query.

Ð ViewName

The value of the "ViewName" attribute. This is the name of the LearningStore view that this query uses to retrieve data.

Methods
Name Description
Ð CreateQuery

Returns a new LearningStoreQuery constructed from this query definition.

Ð RenderQueryRowCells

Given a DataRow from a DataTable returned from a LearningStore query created by CreateQuery, this method returns one RenderedCell for each column in the Columns collection.

ÐS SortRenderedRows

Sorts list of rows, where each row consists of an array of RenderedCell objects.